{% extends "admin/common/layout.html" %}
{% block body %}
<h2>我的信息</h2>
<hr>
{% include "admin/common/flash.html" %}
<form class="form-horizontal" role="form" method="POST" action="{{ url_for('admin.account_edit') }}">
    <input type="hidden" name="id" value="{{ account.id }}">
    <div class="form-group">
        <label for="name" class="col-sm-2 control-label">用户名</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="name" name="name" placeholder="请输入用户名" value="{{ account.name }}"readonly>
        </div>
    </div>

    <div class="form-group">
        <label for="nick_name" class="col-sm-2 control-label">昵称</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="nick_name" name="nick_name" placeholder="请输入昵称" value="{{ account.nick_name }}">
        </div>
    </div>

    <div class="form-group">
        <label for="mobile" class="col-sm-2 control-label">手机号</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="mobile" name="mobile" placeholder="请输入手机号" value="{{ account.mobile }}">
        </div>
    </div>

    <div class="form-group">
        <label for="passwd" class="col-sm-2 control-label">密码</label>
        <div class="col-sm-10">
            <input type="password" class="form-control" id="passwd" name="passwd" placeholder="请输入密码" value="">
        </div>
    </div>

    <div class="form-group">
        <label for="passwd" class="col-sm-2 control-label">密码确认</label>
        <div class="col-sm-10">
            <input type="password" class="form-control" id="passwd_confirm" name="passwd_confirm" placeholder="请再次输入密码" value="">
        </div>
    </div>

    <div class="form-group">
        <label for="role_id" class="col-sm-2 control-label">角色</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="role_id" placeholder="请输入角色" value="{{ role.name }}" readonly>
            <input type="hidden" name="role_id" value="{{ account.role_id }}">
        </div>
    </div>

    <div class="form-group">
        <div class="col-sm-offset-2 col-sm-10" role="toolbar" aria-label="...">
            <div class="btn-group" role="group">
                <button type="submit" class="btn btn-default">保存</button>
            </div>
        </div>
    </div>
</form>
{% endblock %}
